<?php
session_start();
function record_time(){
    if(!isset($_SESSION['countdown'])){
        return ;
    }
    
    if($_SESSION['record_start_time'] == false){
       return ;
    }else{
        array_push($_SESSION['end_times'], time());
        $_SESSION['record_start_time'] = false;
    }
}

$user_input = $_GET['input'];

array_push($_SESSION['user_input'], $user_input);
record_time()
?>